<!DOCTYPE html>
<html lang="en" xmlns:v-bind="http://www.w3.org/1999/xhtml"
      xmlns:v-on="http://www.w3.org/1999/xhtml">
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>大区销售目标预测</title>
    <meta http-equiv="pragma" content="no-cache">
    <meta http-equiv="Cache-Control" content="no-store, must-revalidate">
    <meta http-equiv="expires" content="Wed, 26 Feb 1997 08:21:57 GMT">
    <meta http-equiv="expires" content="-1">
    <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"
          name="viewport">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <link rel="shortcut icon" href="/dist/img/icon.png" type="image/x-icon">
    <!-- Bootstrap 3.3.6 -->
    <link rel="stylesheet" href="/dist/plugins/bootstrap/css/bootstrap.min.css">
    <!--字体-->
    <link rel="stylesheet" href="/dist/css/font-awesome.min.css">
    <!--图标-->
    <link rel="stylesheet" href="/dist/css/ionicons.min.css">
    <!--插件样式-->
    <link rel="stylesheet" href="/dist/plugins/select2/select2.min.css">
    <link rel="stylesheet" href="/dist/plugins/fixedTable/fixed-table.css"/>
    <!--OA主样式-->
    <link rel="stylesheet" href="/dist/css/OA.min.css?t=39cd89cd">
    <link rel="stylesheet" href="/dist/css/skins/OA-skins.min.css?t=16f1e6f3">
    <style>
        .bgOne {
            color: black;
        }

        .bgTwo {
            color: red;
        }

        .bgThree {
            color: #9d9d9d;
        }
        .table > tbody > tr > td {
            height: 30px;
            max-height: 44px;
            overflow: hidden;
            padding: 0 2px;
            border: 1px #cbcbcd solid
        }

        .table > thead > tr > th {
            border: 1px #cbcbcd solid
        }

        tbody {
            font-size: 12px;
        }

        .saveModle {
            width: 500px;
            height: 300px;
            position: fixed;
            top: 50%;
            left: 50%;
            margin-left: -250px;
            margin-top: -150px;
            background: #fff;
            border-radius: 10px;
            z-index: 1978;
            display: none;
            border: 1px solid #cfcfcf;
        }

        .saveModle .top {
            height: 34px;
            line-height: 34px;
            font-size: 14px;
            font-weight: bold;
            color: #333;
            padding-left: 7px;
            border-bottom: 1px solid #cfcfcf;
            background: #fff;
        }

        .saveModle .top .title {
            height: 32px;
            line-height: 32px;
            font-size: 14px;
            font-weight: bold;
            color: #333;
            float: left;
            background: #fff;
        }

        .saveModle .top .btn {
            font-size: 20px;
            width: 34px;
            height: 22px;
            line-height: 12px;
            display: inline-block;
            float: right;
        }

        .saveModle .top .btn:hover {
            color: red;
        }

        .saveModle .saveBtn {
            margin: 0 auto;
            margin-top: 35px;
            display: block;

        }

        .lineOne {
            max-height: 36px;
            line-height: 18px;
            overflow: hidden;
            text-overflow: ellipsis;
            display: -webkit-box;
            -webkit-box-orient: vertical;
            -webkit-line-clamp: 3;
        }

        p {
            display: inline-block;
            float: left;
            margin-bottom: 0px;
            line-height: 25px;
            padding-right: 15px;
            color: #228bee;
            font-size: 14px;
        }

        .td-value span.lineOne {
            overflow: hidden;
            text-overflow: ellipsis;
            color: black !important;
            display: -webkit-box;
            -webkit-box-orient: vertical;
            -webkit-line-clamp: 1;
            max-height: 48px;
            line-height: 24px;
        }

        .td-value span.lineOne1 {
            overflow: hidden;
            text-overflow: ellipsis;
            color: black !important;
            display: -webkit-box;
            -webkit-box-orient: vertical;
            -webkit-line-clamp: 1;
            max-height: 48px;
            line-height: 24px;
        }

        .td-value {
            text-align: left !important;
            vertical-align: middle;
            word-wrap: break-word;
            color: black !important;
        }

        .td-value span {
            display: inline-block;
            overflow: hidden;
            padding-left: 0.06rem;
            word-wrap: break-word;
            color: black !important;
        }

        .fixed-table_body tr td {
            border-right: none;
        }

        .fixed-table_header tr th {
            border-right: none;
            background: yellow;
            font-weight: normal;
            font-size: 12px;
        }

        .input-sm {
            height: 24px;
            padding: 5px 10px;
            font-size: 12px;
            line-height: 24px;
            border-radius: 0px;
        }

        .description {
            display: flex;
            flex-wrap: wrap;
            justify-content: flex-start;
            width: 260px;
            /* margin-left: 395px; */
            /* padding-top: 50px; */
            /* float: right; */
            position: absolute;
            top: -10px;
            right: 0px;
            background: #d3e8fd;
            padding: 5px;
            z-index: 1111;
            border: 1px solid #cbcbcd;
        }

        .mubiao {
            display: block;
            /* justify-content: flex-start; */
            /* position: absolute; */
            /* top: 60px; */
            /* right: 255px; */
            margin: 15px auto;
            height: 60px;
            width: 350px
        }

        .title {
            background: rgb(211, 232, 253) !important;;
        }

        .lineOne span, .lineSpan {
            max-height: 20px;
            line-height: 20px;
            overflow: hidden;
            text-overflow: ellipsis;
            display: -webkit-box;
            -webkit-box-orient: vertical;
            -webkit-line-clamp: 1;
        }

        .text-center td {
            background: #fff;
        }

        /*获取公司*/

        .content {
            padding: 0px 0px 15px 20px;
            padding-bottom: 0;
        }

        #tbList tr td {
            height: 42px !important;
        }

        .fixed-table-box td {
            position: static;
        }

        html, body, #app {
            padding: 0px;
            margin: 0px;
        }

        .fixed-table-box th {
            position: relative;
            text-align: center;
            height: 24px;
            border: 1px solid #cbcbcd;
        }

        .fixed-table-box th {

        }

        .companyMore {
            width: 100%;
            height: 65px;
            position: relative;
            margin-top: 82px;
        }

        .companyOne {
            width: 100%;
            height: 65px;
            position: relative;
            margin-top: 65px;
        }

        .table {
            width: 100%;
            max-width: 100%;
            margin-bottom: 0px;
        }

        .has-feedback .form-control {
            padding-right: 0px;
        }

        .duiqi {
            text-align: justify;
            display: inline-block;
            overflow: hidden;
            vertical-align: middle;
            height: 36px;
            line-height: 24px;
            width: 36px;
        }

        /*获取区域总监*/
        .tabActive {
            text-align: center;
            color: #228bee;
            /*border-bottom: 2px solid #228bee;*/
            margin-left: 8px;
            margin-right: 8px;
            height: 24px;
            line-height: 24px;
        }

        .tabNo {
            text-align: center;
            color: #666666;
            font-size: 12px;
            /*border-bottom: 2px solid #f8f8f8;*/
            margin-left: 8px;
            margin-right: 8px;
            height: 24px;
            line-height: 24px;
        }

        .oa-tab-small {
            display: -webkit-box;
            position: fixed;
            top: 40px;
            overflow-y: hidden;
            -webkit-overflow-scrolling: touch;
            height: 30px;
            width: 100%;
            background: #fff;
            z-index: 1111;
            display: flex;
        }

        .wyTd {
            height: 18px !important;
        }

        .fixed-table_body tr td {
            border-right: none;
            font-size: 12px;
            text-align: center;
            height: 24px;
            max-height: 24px;
            overflow: visible;
        }

        body {
            overflow: hidden;
        }
    </style>
</head>
<body>
<section class="content " style="padding-left:0px;" id="app" v-cloak>
    <div class="oaLoad">
        <div class="loadGif" id="areaProgress"></div>
    </div>
    <div class="div-td-content-more"><i></i></div>
    <iframe id="ifExprot" style="width:0px;height:0px;display: none;" frameborder="0"></iframe>
    <div style="height: 25px;margin-bottom: 10px;margin-top: 50px;">
        <div class="pull-left" style="width: 115px;">
            <select id="selectCompany" class="form-control"
                    style="width: 100%;height: 24px;font-size: 12px;line-height: 24px;padding-top: 0px;padding-bottom: 0px;padding-left: 6px;"
                    v-model="searchParams.selectCom">
                <option value="">请选择公司</option>
                <option v-for="item in companyList" v-bind:value="item.id">{{item.name}}</option>
            </select>
        </div>
        <div class="pull-left" style="width: 127px;margin-left: 10px;">
            <select id="selectCostName" class="form-control"
                    style="height: 24px;font-size: 12px;line-height: 24px;padding-top: 0px;padding-bottom: 0px;padding-left: 6px;"
                    v-model="searchParams.selectCost">
                <option value="">请选择费用名称</option>
                <option v-for="item in costList" v-bind:value="item.costSmallName">{{item.costSmallName}}</option>
            </select>
        </div>
        <input class="pull-left form-control pull-left input-sm" type="text" v-model="searchParams.beginTime"
               @focus="showDatePicker($event)" placeholder="请选择开始时间" style="width: 106px;margin-left: 10px;">
        <input class="pull-left form-control pull-left input-sm" type="text" v-model="searchParams.endTime"
               @focus="endDatePicker($event)" placeholder="请选择结束时间" style="width: 106px;margin-left: 10px;">
        <input type="text" placeholder="人员姓名" class="form-control pull-left input-sm"
               style="width: 75px; margin-left: 10px;" v-model="searchParams.userName" id="txtCoster">
        <input type="hidden" v-model="searchParams.userId">
        <button type="button" class="btn oaBtn btn-sm pull-left" style="margin-left: 10px;" @click="getList">查询</button>
       <!-- <button type="button" class="btn oaBtn btn-sm pull-left" style="margin-left: 10px;" @click="removeSelect">清空
        </button>-->
    </div>
    <div class="box-body no-padding iframeH4" id="scrollDiv">
        <div id="progress" class="wyui-progress"></div>
        <div class="fixed-table-box head-fixed " style="height: 100%">
            <div class="fixed-table_header-wraper">
                <table class="fixed-table_header" cellspacing="0" cellpadding="0" border="0">
                    <!--<table class="table table-hover  text-center" style="margin-top: 20px;">-->
                    <thead>
                    <tr>
                        <th style="width:40px;">
                            <div class="table-cells">序号</div>
                        </th>
                        <th style="width:60px">
                            <div class="table-cells">姓名</div>
                        </th>
                        <th style="width:60px">
                            <div class="table-cells">日期</div>
                        </th>
                        <th style="width:90px">
                            <div class="table-cells">费用名称</div>
                        </th>
                        <th style="width:60px">
                            <div class="table-cells">金额(元)</div>
                        </th>
                        <th style="width:75px">
                            <div class="table-cells">是否有发票</div>
                        </th>
                        <th>
                            <div class="table-cells">备注</div>
                        </th>
                        <th style="width:120px">
                            <div class="table-cells">审核状态</div>
                        </th>
                        <th style="width:120px">
                            <div class="table-cells">操作</div>
                        </th>
                        <th id="tdMore">
                            <div class="table-cells"></div>
                        </th>
                    </tr>
                    </thead>
                </table>
            </div>
            <div class="fixed-table_body-wraper iframeYKFixed" id="divMain" style="height: 100%">
                <table class="fixed-table_body table-hover" id="tableMain" cellspacing="0" cellpadding="0" border="0"
                       style="width: 100%;">
                    <tbody>
                    <tr v-for="(item,i) in list" :class="colors(item.bxState)">
                        <td style="width:40px;"><span>{{i+1}}</span></td>
                        <td style="width:60px;"><span class="oa-name">{{item.userName}}</span></td>
                        <td style="width:60px;"><span>{{formatDate((item.reportDate))}}</span></td>
                        <td style="width:90px;"><span>{{item.costSmallName}}</span></td>
                        <td style="width:60px;"><span>{{item.money}}</span></td>
                        <td style="width:75px;"><span>{{item.invoiceFlag=="1"?"有":"无"}}</span></td>
                        <td style="text-decoration: none;text-align:left" class='td-tanZongStyle-line'><i></i><span
                                class="lineOne">{{item.remark}}</span></td>
                        <td style="width:120px" v-html="convertAuditFlagToName(item)">
                        </td>
                        <td style="width: 120px">
                            <span :attr-type="item.id" attr-pagetype="edit"
                                  v-if="item.auditFlag==0&&currentUser.id==item.currentAuditorId"
                                  style="color:#2a8cec !important;cursor: pointer;text-align: center"
                                  @click="gotoDetail(item,'audit')"
                                  class="td-value changeValue">审核</span>
                            <span :attr-type="item.id" attr-pagetype="edit"
                                  v-else-if="item.auditFlag==2&&currentUser.id==item.userId"
                                  style="color: #2a8cec !important;cursor: pointer;text-align: center"
                                  @click="gotoDetail(item,'edit')"
                                  class="td-value changeValue">编辑</span>
                         <!--   <span v-if="((item.auditFlag==0||item.auditFlag==1)&&currentUser.id==item.userId)||((item.auditFlag==2||item.auditFlag==1)&&currentUser.id==item.currentAuditorId)"-->
                            <span v-else
                                  :attr-type="item.id" attr-pagetype="look"
                                  style="color: #2a8cec !important;cursor: pointer;text-align: center"
                                  @click="gotoDetail(item,'look')"
                                  class="td-value changeValue">查看</span>
                        </td>
                    </tr>
                    </tbody>
                </table>
            </div>

        </div>
        <div class="oa-pager text-center" style="margin-top: 5px;">
            共
            <span id="allCount"> 0 </span>条记录&nbsp;&nbsp;&nbsp;
            <span id="nowPage"> 1 </span>/<span id="allPage">1</span>&nbsp;&nbsp;&nbsp;
            <span class="oa-pager-button" id="first">首页</span>
            <span class="oa-pager-button" id="prev">上一页</span>
            <span class="oa-pager-button" id="next">下一页</span>
            <span class="oa-pager-button" id="last">尾页</span>
        </div>
    </div>


</section>
<!--JQ-->
<script src="https://file.ggxqce.com/web/jquery-2.2.3.min.js"></script>
<!--插件JS-->
<script src="https://file.ggxqce.com/web/bootstrap.min.js"></script>
<!--框架已定义 JS-->
<script src="/dist/js/app_iframe.js?t=7e54a132"></script>
<!--oa自定义  JS-->
<script src="/dist/js/oa.js?t=54c6b89c"></script>
<script src="https://file.ggxqce.com/web/vue.min.js"></script>
<script type="text/javascript" src="/dist/plugins/My97DatePicker/WdatePicker.js"></script>
<script type="text/javascript" src="/dist/plugins/lhgdialog/lhgdialog.min.js?self=true"></script>
<script src="/dist/plugins/webuploader-0.1.5/webuploader.min.js"></script>
<script src="/dist/plugins/fixedTable/fixed-table.js"></script>
<script>
    $(function () {
        $("body").on("click", ".lineOne,.lineTwo", function (e) {
            if ($(".div-td-content-more").is(":hidden")) {
                var text = $(this).text();
                if (text != "") {
                    text = "<i></i>" + text;
                    $(".div-td-content-more").html(text).css({
                        "width": $(this).outerWidth() + 12 + "px",
                        "left": $(this).offset().left - 6,
                        "top": ($(this).offset().top + $(this).outerHeight()) + "px"
                    }).show();
                    e.stopPropagation();
                }
            } else {
                $(".div-td-content-more").hide();
            }
        });
        $("body").on("click", ".div-td-content-more", function (e) {
            e.stopPropagation();
        });
        $("body").on("click", function () {
            $(".div-td-content-more").hide();
        });
    });
</script>
<script type="text/javascript">
    function refresh() {
        $.wyui.page.getByPage();
    }

    var app = new Vue({
        el: '#app',
        data: {
            currentUser: getCurrentUser(),
            selectIndex: '待审核',
            searchParams: {
                selectCom: "",
                selectCost: "",
                beginTime: "",
                endTime: "",
                userName: "",
                costSmallName: "",
                userId: "",
                currentUserId: getCurrentUser().id,
                type: "",
                load: true
            },
            companyList: [],
            costList: [],
            expensesList: [],
            list: [],
            rightOp: [],

        },
        methods: {
            getList: function () {
                var that = this;
                $.wyui.page.queryParams.requestPage = 1;
                if (that.searchParams.userName == "") {
                    that.searchParams.userId = ""
                }
                var data = {
                    'companyId': that.searchParams.selectCom,
                    'beginTime': that.searchParams.beginTime,
                    'endTime': that.searchParams.endTime,
                    'userName': that.searchParams.userName,
                    'costSmallId': that.searchParams.selectCost,
                    'costSmallName': that.searchParams.selectCost,
                    'userId': that.searchParams.userId,
                    'currentUserId': that.searchParams.currentUserId,
                    'load': true
                };
                /*  $.extend($.wyui.page.queryParams, that.searchParams);*/
                $.extend($.wyui.page.queryParams, data);
                console.log($.wyui.page.queryParams);
                $.wyui.page.getByPage();
            },
            removeSelect: function () {
                var that = this;
                that.searchParams.beginTime = "",
                    that.searchParams.endTime = "",
                    that.searchParams.userName = "",
                    that.searchParams.costSmallName = "",
                that.searchParams.selectCom="",
                    that.searchParams.selectCost=""

            },
            convertAuditFlagToName: function (item) {
                switch (item.auditFlag) {
                    case "-1":
                        return "未提交";
                        break;
                    case "0":
                        if (item.currentAuditorId == getCurrentUser().id) {
                            return "<span style='color:red;'>待-" + item.currentAuditorName + "-审核</span>";
                        } else {
                            return "待-" + item.currentAuditorName + "-审核";
                        }
                        break;
                    case "1":
                        return "已通过";
                        break;
                    case "2":
                        if (item.createUserId == getCurrentUser().id) {
                            return "<span style='color:red;'>已驳回</span>";
                        } else {
                            return "已驳回";
                        }
                        break;
                    case "3":
                        return "已作废";
                        break;
                    default :
                        break;
                }
            },
            //日期格式
            formatDate: function (now) {
                return new Date(now).Format(TimeFormat.pcListYR);
            },
            //根据报销状态单行背景色
            colors: function(start) {
                if (start == '0') {
                    return "bgOne";
                } else if (start == '1') {
                    return "bgThree";
                } else if (start == "-1") {
                    return "bgTwo";
                }

            },
            getHeight: function () {
                var allHeight = $("#divMain").height()
                var tableHeight = $("#tableMain").height()
                console.log(allHeight,tableHeight)
                var flag = allHeight >= tableHeight ? true : false
                console.log(flag)
                if (flag) {
                    $('#tdMore').css('width', '0px');
                } else {
                    $('#tdMore').css('width', '17px');
                }
            },
         /*   gotoDetail: function (item, type) {
                top.$.dialog({
                    content: 'url:/page/wreport/wreportCost/costDetail.html?id=' + item.id + '&pageType=' + type,
                    title: "费用详情",
                    width: 804,
                    height: 415,
                    max: true,
                    min: true,
                    lock: true
                });
            },*/

            gotoDetail: function (item,type) {
                if(item.type=='0'){
                    top.$.dialog({
                        content: 'url:/page/wreport/wreportCost/costDetail.html?id=' + item.id+'&pageType='+ type,
                        title: "费用详情",
                        width: 804,
                        height: 415,
                        max: true,
                        min: true,
                        lock: true
                    });
                }else{
                    top.$.dialog({
                        content: 'url:/page/wreport/temporaryExpenses.html?id=' + item.id+'&pageType='+ type,
                        title: "费用详情",
                        width: 804,
                        height: 380,
                        max: true,
                        min: true,
                        lock: true
                    });
                }
            },
            showDatePicker: function (e) {
                var that = this;
                WdatePicker({
                    onpicked: function (dp) {
                        that.searchParams.beginTime = dp.cal.getNewDateStr();
                        return true;
                    },
                    //dateFmt:'yyyy-MM-dd HH:mm'
                });
                $(e.target).blur();
            },
            endDatePicker: function (e) {
                var that = this;
                WdatePicker({
                    onpicked: function (dp) {
                        that.searchParams.endTime = dp.cal.getNewDateStr();
                        return true;
                    },
                });
                $(e.target).blur();
            },

            toAudit: function (item) {

            }

        },
        mounted: function () {
            var that = this;
            $.wyui.postLoadMethod(urlConfig.system.company.getCompanyByUserId, {userId: getCurrentUser().id}, function (r) {
                console.log(r);
                that.companyList = r;
            }, false, false);

//                $.wyui.postLoadMethod(urlConfig.system.rightOp.getRightOpByUserId, {userId: getCurrentUser().id}, function (rightOp) {
//                    for (var i = 0; i < rightOp.length; i++) {
//                        that.rightOp.push(rightOp[i].eName);
//                    }
//                    console.log("权限列表如下：")
//                    console.log(that.rightOp);
//                    //判断用户是否有添加人员的权限
////                if (!getCurrentUser().superUser && !that.isHasRightOp('addUser')) {
////                    $("#addUserBtn").hide();
////                } else {
////                    $("#addUserBtn").show();
////                }
//                }, false, false);

            $.wyui.postLoadMethod(urlConfig.wreport.wreportCost.getCostSmallNameList, {}, function (r) {
                console.log(r);
                that.costList = r;
            }, false, false);

            $.wyui.postLoadMethod(urlConfig.wreport.wreportCost.getAllExpensesType, {}, function (r) {
                console.log(r);
                that.expensesList = r;
            }, false, false);
        }

    })

</script>
<script>
    //初始化FixedTable
    $(".fixed-table-box").fixedTable();
</script>
<script>
    $.wyui.page.dataUrl = server.ip + "/wreportCost/getWaitShByPage.json";
    $.wyui.page.queryParams.pageType = $.wyui.page.urlParams.pageType;
    $.wyui.page.queryParams = {
        requestPage: 1,
        pageSize: 100
    }
    $.extend($.wyui.page.queryParams, app.searchParams);
    $.wyui.page.getByPage_callback = function (records) {
        console.log(records)
        for (var i = 0; i < records.length; i++) {
            records[i].show = false;
            records[i].showActual = false;
        }
        app.list = records;
        setTimeout(function () {
            app.getHeight();
        },200)

//        document.getElementById("scrollDiv").scrollTop = 0;
    };
    $.wyui.page.getByPage_scroll_callback = function (list) {
        if (list.length < 30) {
            isLoad = false;
        } else {
            for (var i = 0; i < list.length; i++) {
                app.list.push(list[i]);
            }
            isLoad = true;
        }
    };
    //自动补全
    $(function () {

        $("#txtCoster").autoComplete({
            url: server.ip + urlConfig.system.user.getCosterTop10ByNameUserRight,
            render: function (users, panel) {
                console.log("users=" + users);
                if (users) {
                    for (var i = 0; i < users.length; i++) {
                        $("<li></li>").data("autoComplete",
                            users[i]).html("<a>" + users[i].name + "&nbsp;&nbsp;&nbsp;" +
                            "(" + "&nbsp;" + users[i].companyName + "-" + users[i].departName + "-" + users[i].roleName + "&nbsp;" + ") " + "</a>")
                            .appendTo(panel);
                    }
                }
            },
            selected: function (user) {
                console.log(user);
                app.searchParams.userId = user.id;
                app.searchParams.userName = user.name;
            },
            extraParams: {userId: getCurrentUser().id},
            height: 210,
            width: 300
        });
    }),
        //自动补全
        $(function () {
                $("#txtCostSmallName").autoComplete({
                    url: server.ip + "/wreportCost/getCosterTop10ByCostName.json",
                    render: function (users, panel) {
                        console.log("users=" + users);
                        if (users) {
                            for (var i = 0; i < users.length; i++) {
                                $("<li></li>").data("autoComplete",
                                    users[i]).html("<a>" + users[i].costName + "</a>")
                                    .appendTo(panel);
                            }
                        }
                    },
                    selected: function (user) {
                        console.log(user);
                        app.searchParams.costSmallName = user.costName;
                    },
                    height: 210,
                    width: 300
                });
            },
            Vue.directive('line-inserted', {
                inserted: function (el, binding) {
                    console.log(el);
                    var lineIndex = binding.value;
                    renderLines(el, lineIndex);
                }
            })
        );

</script>
<script>
    /************************滚动加载******************************/
    var divscroll = document.getElementById('scrollDiv');

    function divScroll() {
        var wholeHeight = divscroll.scrollHeight;
        var scrollTop = divscroll.scrollTop;
        var divHeight = divscroll.clientHeight;
        console.log(scrollTop + divHeight, wholeHeight)
        if (scrollTop + divHeight >= wholeHeight - 2) {
//            alert('滚动到底部了！');
            if (isLoad) {
                isLoad = false;
                setTimeout($.wyui.page.getByPage("scroll"), 1000);

            }

            //这里写动态加载的逻辑，比如Ajax请求后端返回下一个页面的内容
        }

    }

    //    divscroll.onscroll = divScroll;
</script>
<script>
    //初始化FixedTable
    $(".fixed-table-box").fixedTable();
</script>

</body>
</html>